from email.policy import default
from sqlalchemy import Column, Integer, String, ForeignKey
from sqlalchemy.orm import relationship

from app.db import Base


class Compute(Base):
    __tablename__ = 'compute'

    id = Column(Integer, primary_key=True, index=True)
    service_id = Column(String(255), unique=True)
    size = Column(Integer, default=None)
    mainnode = Column(String(255), default=None)
    main_memory = Column(Integer, default=128)
    slave_memory = Column(Integer, default=None)
    type = Column(Integer, default=None)
    time = Column(String(255), default=None)
